|
|
|
|
|
|
|
Figure 15.15.
The results of a one-sided DELETE using anINNER JOIN. |
|
|
|
|
|
|
|
|
You have learned how to add, delete, and edit data within tables using the DML (Data Manipulation Language) SQL keywords. You've learned that, by using DML statements, you can quickly create test data for tables and load default values into startup tables. You also learned that DML statementssuch as Append queries, Make Table queries, and Delete queriescan outperform equivalent Visual Basic code versions of the same operations. |
|
|
|
|
|
|
|
|
You learned how to manage data within the tables using the following DML keywords: |
|
|
|
|
|
|
|
|
· The INSERT INTO statement can be used to add new rows to the table using the VALUES clause. |
|
|
|
|
|
|
|
|
· You can create an Append query by using the INSERT INTO_FROM syntax to copy data from one table to another. You can also copy data from one database to another using the IN clause of an INSERT INTO_FROM statement. |
|
|
|
|
|
|
|
|
· You can create new tables by copying the structure and some of the data using the SELECT_INTO statement. This statement can incorporate WHERE, ORDER BY, GROUP BY, and HAVING clauses to limit the scope of the data used to populate the new table you create. |
|
|
|
|
|
|
|
|
· You can use the DELETE FROM clause to remove one or more records from an existing table. You can even create customized views of the database using the JOIN clause and remove only records that are the result of a JOIN statement. |
|
|
|
|
|